﻿package com.view.my_view;

import com.badibadi.uniclubber.R;

import android.content.Context;
import android.graphics.Color;
import android.graphics.drawable.ColorDrawable;
import android.graphics.drawable.Drawable;
import android.text.TextWatcher;
import android.util.AttributeSet;
import android.widget.CheckBox;
import android.widget.RadioButton;

public class MyCheckBox extends CheckBox {

	public MyCheckBox(Context context, AttributeSet attrs) {
		super(context, attrs);
		// TODO Auto-generated constructor stub
	}

	public MyCheckBox(Context context) {
		// TODO Auto-generated constructor stub
		super(context);
	}

	@Override
	public void addTextChangedListener(TextWatcher watcher) {
		// TODO Auto-generated method stub
		super.addTextChangedListener(watcher);
	}

	@Override
	public void setButtonDrawable(Drawable d) {
		// TODO Auto-generated method stub
		super.setButtonDrawable(null);
	}

	@Override
	public void setChecked(boolean checked) {
		// TODO Auto-generated method stub
		super.setChecked(checked);
		if (checked == false) {
			this.setBackgroundResource(R.drawable.check_false);
		} else {
			this.setBackgroundResource(R.drawable.check_true);
		}
	}
}
// @Override
// public void setBackgroundResource(int resid) {
// // TODO Auto-generated method stub
// super.setBackgroundResource(resid);
